﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Presentation/master.Master" AutoEventWireup="true" CodeBehind="StationeryRequisitionForm.aspx.cs" Inherits="Staionery_Inventory.StationeryRequisitionForm" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <br />
<div class="row">
<asp:Label ID="lblRequestIDText" runat="server" CssClass="col-sm-3 text-info" Text="" />
<asp:Label ID="lblRequestID" runat="server" CssClass="col-sm-9 text-left" Text="" />
</div>
<div class="row">
<asp:Label ID="lblDepartment" runat="server" CssClass=" col-sm-3 text-info" Text="Department Name:" />
<asp:Label ID="lblDepartmentName" runat="server" CssClass="col-sm-9 text-left" Text=""  />
</div>
<br />

<div class="row" onkeypress="return keypress(event)" >
<asp:GridView runat="server"  ID="gvStationeryRequisition" 
        CssClass="col-sm-12 table table-striped table-bordered table-hover"  
        AutoGenerateColumns="False" ClientIDMode="Static" 
        onrowdeleting="gvStationeryRequisition_RowDeleting" >
       <Columns>
             <asp:BoundField DataField="ItemID" HeaderText="Item Number" />
             <asp:BoundField DataField="Description" HeaderText="ItemName" />
                <asp:TemplateField HeaderText="Quantity">
                    <ItemTemplate>
                <%--      MaximumValue='<%# Eval("QtyLeft") %>' from textbox --%>
                        <asp:TextBox ID="txtQuatity" runat="server" CssClass="text-left" 
                            Text='<%# Eval("QtyLeft") %>' 
                            ontextchanged="txtQuatity_TextChanged1" ></asp:TextBox>
                         <%--
                           <input type="text" ID="txtQuatity" runat="server" class="text-left" 
                              value='<%# Eval("QtyLeft") %>' onkeypress="return keypress(event)" 
                            onchange="txtQuatity_TextChanged1" />--%>
                        
                    </ItemTemplate>
                    <ItemStyle HorizontalAlign="Justify" />
                </asp:TemplateField>
                <asp:BoundField DataField="UnitOfMeasure" HeaderText="Unit of Measurement" >
                <ItemStyle HorizontalAlign="Justify" />
                </asp:BoundField>
              <asp:CommandField ShowDeleteButton="True" >
              <ItemStyle HorizontalAlign="Justify" CssClass="btn-default" />
              </asp:CommandField>
            </Columns>
</asp:GridView>
</div>

<div class="row">
<div class="col-md-2">
<asp:label ID="lblSpecialRequest" runat="server" Text="Special Request" CssClass="text-info" />
</div>
<div class="col-md-2">
<asp:TextBox ID="txtSpecialRequest" runat="server" placeholder="Please fill your special request" TextMode="MultiLine" CssClass="text-left"></asp:TextBox>
</div>
</div>

<br />

<div class="row">
<div class="col-md-2">
<asp:Button ID="btnsubmit" runat="server" Text="Submit" CssClass="btn btn-default" 
        OnClientClick="Confrim()" onclick="btnsubmit_Click" />
        <%--<asp:HiddenField ID="hfconfirm" runat="server" ClientIDMode="Static" />--%>
</div>
<div class="col-md-2 ">
<asp:Button ID="btnAddmore" runat="server" Text="Add more" 
        CssClass="btn btn-default" onclick="btnAddmore_Click"  />

</div>
<div class="col-md-2">
<asp:Button ID="btnCancel" runat="server" Text="Back" 
        CssClass="btn btn-default"  Visible="false" onclick="btnCancel_Click" />
</div>
</div>
<asp:Label ID="lblErrorText" runat="server" CssClass=" text-danger" />
</asp:Content>
